using System.Collections;
using System.Xml;
using Altova.TypeInfo;
using Altova.Xml;
using Altova.Xml.Meta;

namespace RDML_v1_2_REC.rdml
{
	public class sequencesType : TypeBase
	{
		internal class Enumerator : EnumeratorBase
		{
			public override object Current
			{
				get
				{
					return new sequencesType((XmlNode)base.InnerCurrent);
				}
			}

			public Enumerator(IEnumerator inner)
				: base(inner)
			{
			}
		}

		public class MemberElement_forwardPrimer : IEnumerable
		{
			private TypeBase owner;

			private MemberInfo info;

			public oligoType this[int i]
			{
				get
				{
					return At(i);
				}
			}

			public oligoType First
			{
				get
				{
					return new oligoType(owner.GetElementFirst(info));
				}
			}

			public oligoType Last
			{
				get
				{
					return new oligoType(owner.GetElementLast(info));
				}
			}

			public bool Exists
			{
				get
				{
					return Count > 0;
				}
			}

			public int Count
			{
				get
				{
					return owner.CountElement(info);
				}
			}

			public Element Info
			{
				get
				{
					return new Element(info);
				}
			}

			public MemberElement_forwardPrimer(TypeBase owner, MemberInfo info)
			{
				this.owner = owner;
				this.info = info;
			}

			public oligoType At(int index)
			{
				return new oligoType(owner.GetElementAt(info, index));
			}

			public oligoType Append()
			{
				return new oligoType(owner.CreateElement(info));
			}

			public void Remove()
			{
				owner.RemoveElement(info);
			}

			public void RemoveAt(int index)
			{
				owner.RemoveElementAt(info, index);
			}

			public IEnumerator GetEnumerator()
			{
				return new oligoType.Enumerator(XmlTreeOperations.GetElements(owner.Node, info).GetEnumerator());
			}
		}

		public class MemberElement_reversePrimer : IEnumerable
		{
			private TypeBase owner;

			private MemberInfo info;

			public oligoType this[int i]
			{
				get
				{
					return At(i);
				}
			}

			public oligoType First
			{
				get
				{
					return new oligoType(owner.GetElementFirst(info));
				}
			}

			public oligoType Last
			{
				get
				{
					return new oligoType(owner.GetElementLast(info));
				}
			}

			public bool Exists
			{
				get
				{
					return Count > 0;
				}
			}

			public int Count
			{
				get
				{
					return owner.CountElement(info);
				}
			}

			public Element Info
			{
				get
				{
					return new Element(info);
				}
			}

			public MemberElement_reversePrimer(TypeBase owner, MemberInfo info)
			{
				this.owner = owner;
				this.info = info;
			}

			public oligoType At(int index)
			{
				return new oligoType(owner.GetElementAt(info, index));
			}

			public oligoType Append()
			{
				return new oligoType(owner.CreateElement(info));
			}

			public void Remove()
			{
				owner.RemoveElement(info);
			}

			public void RemoveAt(int index)
			{
				owner.RemoveElementAt(info, index);
			}

			public IEnumerator GetEnumerator()
			{
				return new oligoType.Enumerator(XmlTreeOperations.GetElements(owner.Node, info).GetEnumerator());
			}
		}

		public class MemberElement_probe1 : IEnumerable
		{
			private TypeBase owner;

			private MemberInfo info;

			public oligoType this[int i]
			{
				get
				{
					return At(i);
				}
			}

			public oligoType First
			{
				get
				{
					return new oligoType(owner.GetElementFirst(info));
				}
			}

			public oligoType Last
			{
				get
				{
					return new oligoType(owner.GetElementLast(info));
				}
			}

			public bool Exists
			{
				get
				{
					return Count > 0;
				}
			}

			public int Count
			{
				get
				{
					return owner.CountElement(info);
				}
			}

			public Element Info
			{
				get
				{
					return new Element(info);
				}
			}

			public MemberElement_probe1(TypeBase owner, MemberInfo info)
			{
				this.owner = owner;
				this.info = info;
			}

			public oligoType At(int index)
			{
				return new oligoType(owner.GetElementAt(info, index));
			}

			public oligoType Append()
			{
				return new oligoType(owner.CreateElement(info));
			}

			public void Remove()
			{
				owner.RemoveElement(info);
			}

			public void RemoveAt(int index)
			{
				owner.RemoveElementAt(info, index);
			}

			public IEnumerator GetEnumerator()
			{
				return new oligoType.Enumerator(XmlTreeOperations.GetElements(owner.Node, info).GetEnumerator());
			}
		}

		public class MemberElement_probe2 : IEnumerable
		{
			private TypeBase owner;

			private MemberInfo info;

			public oligoType this[int i]
			{
				get
				{
					return At(i);
				}
			}

			public oligoType First
			{
				get
				{
					return new oligoType(owner.GetElementFirst(info));
				}
			}

			public oligoType Last
			{
				get
				{
					return new oligoType(owner.GetElementLast(info));
				}
			}

			public bool Exists
			{
				get
				{
					return Count > 0;
				}
			}

			public int Count
			{
				get
				{
					return owner.CountElement(info);
				}
			}

			public Element Info
			{
				get
				{
					return new Element(info);
				}
			}

			public MemberElement_probe2(TypeBase owner, MemberInfo info)
			{
				this.owner = owner;
				this.info = info;
			}

			public oligoType At(int index)
			{
				return new oligoType(owner.GetElementAt(info, index));
			}

			public oligoType Append()
			{
				return new oligoType(owner.CreateElement(info));
			}

			public void Remove()
			{
				owner.RemoveElement(info);
			}

			public void RemoveAt(int index)
			{
				owner.RemoveElementAt(info, index);
			}

			public IEnumerator GetEnumerator()
			{
				return new oligoType.Enumerator(XmlTreeOperations.GetElements(owner.Node, info).GetEnumerator());
			}
		}

		public class MemberElement_amplicon : IEnumerable
		{
			private TypeBase owner;

			private MemberInfo info;

			public oligoType this[int i]
			{
				get
				{
					return At(i);
				}
			}

			public oligoType First
			{
				get
				{
					return new oligoType(owner.GetElementFirst(info));
				}
			}

			public oligoType Last
			{
				get
				{
					return new oligoType(owner.GetElementLast(info));
				}
			}

			public bool Exists
			{
				get
				{
					return Count > 0;
				}
			}

			public int Count
			{
				get
				{
					return owner.CountElement(info);
				}
			}

			public Element Info
			{
				get
				{
					return new Element(info);
				}
			}

			public MemberElement_amplicon(TypeBase owner, MemberInfo info)
			{
				this.owner = owner;
				this.info = info;
			}

			public oligoType At(int index)
			{
				return new oligoType(owner.GetElementAt(info, index));
			}

			public oligoType Append()
			{
				return new oligoType(owner.CreateElement(info));
			}

			public void Remove()
			{
				owner.RemoveElement(info);
			}

			public void RemoveAt(int index)
			{
				owner.RemoveElementAt(info, index);
			}

			public IEnumerator GetEnumerator()
			{
				return new oligoType.Enumerator(XmlTreeOperations.GetElements(owner.Node, info).GetEnumerator());
			}
		}

		public MemberElement_forwardPrimer forwardPrimer;

		public MemberElement_reversePrimer reversePrimer;

		public MemberElement_probe1 probe1;

		public MemberElement_probe2 probe2;

		public MemberElement_amplicon amplicon;

		public static ComplexType StaticInfo
		{
			get
			{
				return new ComplexType(RDML_v1_2_REC_TypeInfo.binder.Types[RDML_v1_2_REC_TypeInfo._altova_ti_rdml_altova_sequencesType]);
			}
		}

		public sequencesType(XmlNode init)
			: base(init)
		{
			instantiateMembers();
		}

		private void instantiateMembers()
		{
			forwardPrimer = new MemberElement_forwardPrimer(this, RDML_v1_2_REC_TypeInfo.binder.Members[RDML_v1_2_REC_TypeInfo._altova_mi_rdml_altova_sequencesType_altova_forwardPrimer]);
			reversePrimer = new MemberElement_reversePrimer(this, RDML_v1_2_REC_TypeInfo.binder.Members[RDML_v1_2_REC_TypeInfo._altova_mi_rdml_altova_sequencesType_altova_reversePrimer]);
			probe1 = new MemberElement_probe1(this, RDML_v1_2_REC_TypeInfo.binder.Members[RDML_v1_2_REC_TypeInfo._altova_mi_rdml_altova_sequencesType_altova_probe1]);
			probe2 = new MemberElement_probe2(this, RDML_v1_2_REC_TypeInfo.binder.Members[RDML_v1_2_REC_TypeInfo._altova_mi_rdml_altova_sequencesType_altova_probe2]);
			amplicon = new MemberElement_amplicon(this, RDML_v1_2_REC_TypeInfo.binder.Members[RDML_v1_2_REC_TypeInfo._altova_mi_rdml_altova_sequencesType_altova_amplicon]);
		}

		public void SetXsiType()
		{
			XmlTreeOperations.SetAttribute(base.Node, "xsi:type", "http://www.w3.org/2001/XMLSchema-instance", new XmlQualifiedName("sequencesType", "http://www.rdml.org"));
		}
	}
}
